<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>34 Class-static静态成员</title>
</head>

<body>
    <script>
        // // ES5
        // function Phone() {

        // }
        // Phone.prototype.size = '5.5inch';
        // Phone.name = '手机';
        // Phone.change = function () {
        //     console.log('IIII');
        // }
        // let nokia = new Phone();
        // console.log(nokia.size);
        // console.log(nokia.name);
        // nokia.change();

        class Phone {
            static name = '手机';
            static change() {
                console.log('I can change');
            }
        }

        let nokia = new Phone();
        console.log(nokia.name);
        console.log(nokia.change);
        console.log(Phone.name);
        Phone.change();
    </script>
</body>

</html>